package com.atmk.atmk.designMode.创建型.工厂模式.抽象工厂.具体工厂;

import com.atmk.atmk.designMode.创建型.工厂模式.抽象工厂.具体产品.TruckA;
import com.atmk.atmk.designMode.创建型.工厂模式.抽象工厂.抽象产品.Car;
import com.atmk.atmk.designMode.创建型.工厂模式.抽象工厂.抽象产品.Truck;
import com.atmk.atmk.designMode.创建型.工厂模式.抽象工厂.抽象工厂.VehicleFactory;

// 具体工厂：卡车工厂
public class TruckFactory implements VehicleFactory {
    @Override
    public Car produceCar() {
        throw new UnsupportedOperationException("TruckFactory does not produce cars.");
    }

    @Override
    public Truck produceTruck() {
        // 某些具体的卡车生产过程
        return new TruckA();
    }
}

